package com.infore.siteManagement.externalInterface;

import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.ResponseBody;

import com.infore.siteManagement.util.ResultEntity;

@FeignClient(name="IdentityManagement-Service", url="localhost:60008/IdentityManagement-Service/")
public interface IdentityManagement {

	/**根据id拿到运营中心**/
	@RequestMapping(value = "opCen/getTOpCenById", method = RequestMethod.GET)
	@ResponseBody
	public ResultEntity getTOpCenById(@RequestParam(value="id") String id);
	
	/**根据id拿到分公司**/
	@RequestMapping(value = "branchOfc/getTBranchOfcById", method = RequestMethod.GET)
	@ResponseBody
	public ResultEntity getTBranchOfcById(@RequestParam(value="id") String id);
	
	/**根据id查询人员**/
	@RequestMapping(value = "users/ids", method = RequestMethod.GET)
	@ResponseBody
	public ResultEntity getUserByIds(@RequestParam(value="userIds") String userIds);
	
	/**根据id查询人员**/
	@RequestMapping(value = "users/id", method = RequestMethod.GET)
	@ResponseBody
	public ResultEntity getUserById(@RequestParam(value="userId") String userId);
	
	/**查询运维分公司**/
	@RequestMapping(value = "branchOfc", method = RequestMethod.GET)
	@ResponseBody
	public  ResultEntity getTBranchOfcs(@RequestParam(value="key")String key, 
			@RequestParam(value="pageSize")Integer pageSize, 
			@RequestParam(value="pageNo")Integer pageNo);
}
